package com.jzg.jcptadmin.data.vo;

import java.util.Comparator;

/**
 * 
 * @author Mr.Z
 */
public class PinyinComparator implements Comparator<SourceData.TableEntity> {

	public int compare(SourceData.TableEntity o1, SourceData.TableEntity o2) {
		if(o1.getSortLetters().equals("@") || o2.getSortLetters().equals("#")) {
			return -1;
		} else if(o1.getSortLetters().equals("#") || o2.getSortLetters().equals("@")) {
			return 1;
		} else {
			return o1.getSortLetters().compareTo(o2.getSortLetters());
		}
	}

}
